package com.kaoker.system.entity;

import java.util.HashSet;
import java.util.Set;

/**
 * 知识点 --> 考试点 --> 真题
 * 
 * @author bladestone
 *
 */
public class KeyNotePoint implements java.io.Serializable {
	private static final long serialVersionUID = 8742980801305838197L;

	private Long id;
    
    private String name;
    private String description;
    private Section section;
    private String reference;
    
    //相关的考点
    private Set<ExamPoint> referExamPoints = new HashSet();
    //相关的知识点
    private Set<KeyNotePoint> referKeyNotePoints = new HashSet();
    //相关的真题
    private Set<Exercise> referExercises = new HashSet();
    
    public KeyNotePoint(){
    	
    }

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public Section getSection() {
		return section;
	}

	public void setSection(Section section) {
		this.section = section;
	}

	public Set<ExamPoint> getReferExamPoints() {
		return referExamPoints;
	}

	public void setReferExamPoints(Set<ExamPoint> referExamPoints) {
		this.referExamPoints = referExamPoints;
	}

	public Set<KeyNotePoint> getReferKeyNotePoints() {
		return referKeyNotePoints;
	}

	public void setReferKeyNotePoints(Set<KeyNotePoint> referKeyNotePoints) {
		this.referKeyNotePoints = referKeyNotePoints;
	}

	public Set<Exercise> getReferExercises() {
		return referExercises;
	}

	public void setReferExercises(Set<Exercise> referExercises) {
		this.referExercises = referExercises;
	}

	public String getReference() {
		return reference;
	}

	public void setReference(String reference) {
		this.reference = reference;
	}
	
	public void addRefKeyNotePoint(KeyNotePoint keyNotePoint) {
		this.referKeyNotePoints.add(keyNotePoint);
		keyNotePoint.getReferKeyNotePoints().add(this);
	}
	
	public void addRefExercise(Exercise refExercise) {
		this.referExercises.add(refExercise);
		//refExercise.getReferKeyNotesPoints().add(this);
	}
	
	public void addRefExamPoint(ExamPoint examPoint) {
		this.referExamPoints.add(examPoint);
		//examPoint.getReferKeyNotePoints().add(this);
	}	
}
